package cn.bellychang.db1.service;

import cn.bellychang.annotation.HfiDataSource;
import cn.bellychang.db1.model.Synonym;
import cn.bellychang.db1.repository.SynonymRepository;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Component;

import java.util.List;

/**
 * @author ChangLiang
 * @date 2020/9/10
 */
@Component
public class SynonymService {

    @Autowired
    private SynonymRepository repository;

    @HfiDataSource("queryDb")
    public List<Synonym> findAll() {
        return repository.findAll();
    }
}
